Closed
Description
Bug description
As discussed on Discord I'm encountering problem while trying to pre-select something different than te default Project-Level SDK (JDK 11
on Intellij 2022.2.4)
Got help from @felladrin who suggested to create this issue, telling that the problem may be located around here
Steps to reproduce
You can start a gitpod instance with JDK pre-installed :
FROM gitpod/workspace-full
USER gitpod
RUN bash -c ". /home/gitpod/.sdkman/bin/sdkman-init.sh && \
sdk install java 8.0.352-zulu && \
sdk default java 8.0.352-zulu"
ENV IDEA_JDK /home/gitpod/.sdkman/candidates/java/current
ENV JAVA_HOME /home/gitpod/.sdkman/candidates/java/current
But Project-level JDK remains with pre-bundled JDK 11 :
Workspace affected
No response
Expected behavior
I would expect that Project-Level JDK should be set to globally-configured JDK (in case above, JDK 8)
Example repository
FROM gitpod/workspace-full
USER gitpod
RUN bash -c ". /home/gitpod/.sdkman/bin/sdkman-init.sh && \
sdk install java 8.0.352-zulu && \
sdk default java 8.0.352-zulu"
ENV IDEA_JDK /home/gitpod/.sdkman/candidates/java/current
ENV JAVA_HOME /home/gitpod/.sdkman/candidates/java/current
Anything else?
It could be related to a Jetbrains issue here regarding JDK Detector.